#ifndef TEST_H
#define TEST_H

#include <QObject>
#include "testnode.h"

class Test : public QObject
{
public:
    Test();
    Test(const Test &test);

    void setName(const QString &name);
    void addNode(TestNode node);
    void setCountVis(quint32 countVis);
    void setNodeList(QList<TestNode> nodeList);
    void setCurrentTestNodeId(quint32 id);

    QString getName() const;
    TestNode getTestNodeById(quint32 id);
    bool next(TestNode &testNode);
    quint32 count() const;
    quint32 getCountVis() const;
    QList<TestNode> getNodeList() const;
    quint32 getCurrentTestNodeId() const;

    Test& operator =(const Test &test);

private:
    QString name;
    quint32 countVis;
    QList<TestNode> nodeList;
    quint32 currentTestNodeId;
};

QDataStream &operator <<(QDataStream &out, const Test &test);
QDataStream &operator >>(QDataStream &in, Test &test);

#endif // TEST_H
